﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc;
using User.API.Data.Core;

namespace User.API.Controllers
{
    [Produces("application/json")]
    //[Route("api/Base")]
    public class BaseController : Controller
    {
        protected ApplicationUser UserIdentity
        {
            get
            {
                var user = new ApplicationUser();
                var claimes = User.Claims.ToList();
                var id = User.FindFirst("Id");
                //int.TryParse(User.Claims.FirstOrDefault(c => c.Type.Equals("id")).Value, out int id);
                user.Id = 1;
                return user;
            }
        }
    }
}